<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <script src="https://cdn.jsdelivr.net/npm/echarts@4.7.0/dist/echarts.min.js"></script>
  <style>
    #chart {
      width: 800px;
      height: 600px;
    }
  </style>
</head>

<body>
  <div id="chart"></div>
  <script>
    const chartDom = document.getElementById('chart')

    const chart = echarts.init(chartDom)

    chart.setOption({
      title: {
        text: '快速入门Echarts开发'
      },
      xAxis: {
        data: ['食品', '数码', '服饰', '箱包']
      },
      yAxis: {},
      series: {
        type: 'bar',
        data: ['100', '120', '80', '150']
      }
    })
  </script>
</body>

</html>